<?php
/**
 * Created by PhpStorm.
 * User: LuoQin
 * Date: 2015/10/1
 * Time: 13:45
 */

namespace Api\Controller;
use Think\Controller;

class CommandController extends Controller
{

    /**
     * 手机端COMMAND
     */
    private $mobile_command = array(
        'login','reg','orderList','addressList','commonType','addAddress','modiAddress','delAddress','delOrder','createOrder',
        'orderNote','addressNote','modiUserPassword','getOrdersById','getMyOrders','getAllArea','valid','modiUserCid',
        'userSignNode','newsList','modiUserHeadimg','updateV','orderPickCount','payOrder','orderStatusChange','userNote',
        'modiOrderType','orderTrack','getAppCode','moneyList','modiUserName','getCode','checkLoginCode','staffLocation','daiConOrders',
        'addUserAccountPw','modiUserAccountPw','checkAppPay','pioneerAdress','companyRelationList','getCompanyList','runUserCertification',
        'runCompanyCertification','userCertification'
    );

    function searchCommand($command,$type=0){
        if(empty($command)){
            return false;
        }else{
            if($type==0){
                //手机端COMMAND
                return in_array($command,$this->mobile_command);
            }else{
                return false;
            }
        }
    }
}